package com.chen.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.chen.dto.SetmealDto;
import com.chen.entity.Setmeal;
import com.chen.entity.SetmealDish;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

public interface SetmealService extends IService<Setmeal> {
    /**
     * 分页查询
     *
     * @param page
     * @param pageSize
     * @param name
     * @return
     */
    Page<SetmealDto> setmealpage(int page, int pageSize, String name);

    void add(SetmealDto setmealDto);

    SetmealDto findOne(long id);

    void upDate(SetmealDto setmealDto);

    void status(long[] ids, int status);

    @Transactional
    void delt(List<Long> ids);

    List<Setmeal> findByid(Long categoryId, Integer status);

    List<SetmealDish> get(Long setmealId);
}
